package com.yhn.hxds.common.enums;

/**
 * 用户业务错误码
 *
 * @author yhn
 * @version 1.0
 * @description
 * @date 2024/7/22 17:00
 */
public enum UserErrorEnums implements IErrorCode {

    USER_FAIL_TOKEN("A00200", "用户token验证失败"),
    USER_NULL("B00200", "用户不存在"),
    USER_NAME_EXITS("B00201", "用户名已存在"),
    USER_EXITS("B00202", "用户记录已存在"),
    USER_SAVE_ERROR("B00203", "用户记录保存失败"),
    USER_UPDATE_ERROR("B00204", "用户修改记录失败"),
    USER_LOGIN_ERROR("B00205", "用户已登录"),
    USER_NOT_LOGIN("B00206", "用户未登录");

    private final String code;

    private final String message;

    UserErrorEnums(String code, String message) {
        this.code = code;
        this.message = message;
    }

    @Override
    public String code() {
        return code;
    }

    @Override
    public String message() {
        return message;
    }
}
